<template>
    <div>
        <button @click="ctrl1 = true">出现</button>
        <button @click="ctrl1 = false">消失</button>

        <h1 v-if="ctrl1">头像管理</h1>
        <h1 v-if="ctrl">后台管理</h1>
        <h1 v-else="ctrl1">隐藏后台管理</h1>


    </div>
    <button @click="ctrl1 = !ctrl1">出现</button>
    <button @click="ctrl1 = false">消失</button>
     <br>
    <img v-show="ctrl1" src="./12.jpg" alt="">
</template>

<script setup>
import { ref } from 'vue';

const ctrl = ref(true)
const ctrl1 = ref(false)
</script>

<style>
img {
    height: 100px;
    width: 100px;
}
</style>